import request from '@/utils/request'
import {ref} from 'vue'
export default () => {
  const swipers = ref([])
  const getSwipers = async () => {
    let {data} = await request.get('mini/swiper')
    swipers.value = data.map(item=>{
		return {
			img:item.url,
			title:item.title,
			url:item.url,
			opentype : 'click'
		}
	})
  }

  return {
    getSwipers,
    swipers
  }
}
